#include<iostream>
#include<stdio.h>
#include<conio.h>
using namespace std;
class A
{
public:
	void x()
	{
		cout<<"I am x"<<endl;
	}
};
class B:public A
{
public:
	void x()
	{
		cout<<"I am xx"<<endl;
	}
	void y()
	{
		cout<<"I am  y";
	}
};
void main()
{
	A *a1= new A();
	A *a2= new B();
	a1->x();
	a2->x();
	getch();
}